﻿function showonlyone(thechosenone) {
      var newboxes = document.getElementsByTagName("div");
            for(var x=0; x<newboxes.length; x++) {
                  name = newboxes[x].getAttribute("class");
                  if (name == 'stackLinks') {
                        if (newboxes[x].id == thechosenone) {
                            newboxes[x].style.display = 'block';

                            //  Highlight current hack

                            //  The 'current'
                            if (newboxes[x].id == 'newboxes1') {
                                //document.getElementById('link1').style.color = 'white';
                                //document.getElementById('link2').style.color = '#7a7368';
                                document.getElementById('image1').style.display = 'block';
                                document.getElementById('image2').style.display = 'none';
                            }
                            else {
                                //document.getElementById('link1').style.color = '#7a7368';
                                //document.getElementById('link2').style.color = 'white';
                                document.getElementById('image1').style.display = 'none';
                                document.getElementById('image2').style.display = 'block';
                            }
                            
                        }
                        else {
                            newboxes[x].style.display = 'none';
                        }
                  }
            }
}